package Dao.impl;

import Dao.BaseDao;
import Dao.MusicBoxesDao;
import pojo.MusicBoxes;

public class MusicBoxesImpl extends BaseDao<MusicBoxes> implements MusicBoxesDao {
    @Override
    public boolean insertMusicBoxes(int userId, int songId) {
        String sql = "insert into musicboxes(userId, songId) values(?, ?)";
        return update(sql, userId, songId) > 0;
    }

    @Override
    public boolean deleteMusicBoxes(int musicBoxesId) {
        String sql = "delete from MusicBoxes where musicBoxId = ?";
        return update(sql, musicBoxesId) > 0;
    }
}
